IF  EXISTS (SELECT * FROM sys.foreign_keys WHERE object_id = OBJECT_ID(N'[dbo].[FK_SrvrInstnc_SrvrInstncGrp]') AND parent_object_id = OBJECT_ID(N'[dbo].[SrvrInstnc]'))
BEGIN
     ALTER TABLE [dbo].[SrvrInstnc] DROP CONSTRAINT [FK_SrvrInstnc_SrvrInstncGrp]
END
GO

ALTER TABLE [dbo].[SrvrInstnc] WITH CHECK ADD CONSTRAINT [FK_SrvrInstnc_SrvrInstncGrp] 
     FOREIGN KEY([SrvrInstncGrpId]) REFERENCES [dbo].[SrvrInstncGrp] ([SrvrInstncGrpId])
GO
